#pragma once

#include "SourceCode/Scene/Entity.h"

namespace Hazal
{
	class CScene;

	class CScriptableEntity
	{
		friend class CScene;

	public:
		virtual ~CScriptableEntity() {}

	public:
		template<typename T>
		T& GetComponent()
		{
			return m_entity.GetComponent<T>();
		}

	protected:
		virtual void OnCreate() {}

		virtual void OnDestroy() {}

		virtual void OnUpdate(float fTimeSpan) {}

	private:
		CEntity m_entity;
	};
}
